home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 7 / Apprentice-Release7.iso / Source Code / PowerPlant / LEnhancedIconPane / LEnhancedIconPane.h < prev   
Encoding:
Text File  |  1996-09-14  |  2.0 KB  |  58 lines  |  [TEXT/CWIE]

  1. // ===========================================================================
  2. //    File:                    LEnhancedIconPane.h
  3. //  Version:                1.0 - Feb 08,1996
  4. //    Author:                    Mike Shields (mshields@inconnect.com)
  5. //
  6. //    Copyright ©1996 Mike Shields. All rights reserved.
  7. // ===========================================================================
  8. //    LEnhancedIconPane.cp            <- double-click + Command-D to see class definition
  9. //
  10. //
  11. // LEnhancedIconPane is an enhancement to the PP supplied LIconPane Class. This
  12. // subclass give the user the ability to specify all of the parameters in the call
  13. // to PlotIconID. Namely the alignment, label and selection property.
  14. //
  15. // Note: For more info on the PlotIconID calls see TN QD 18 - 
  16. // Drawing Icons the System 7 Way
  17. //
  18. #pragma once
  19.  
  20. #include <LIconPane.h>
  21.  
  22. class LStream;
  23.  
  24. class LEnhancedIconPane : public LIconPane 
  25. {
  26.     public:
  27.         enum { class_ID = 'Eicn' };
  28.         static LEnhancedIconPane*    CreateFromStream(LStream *inStream);
  29.                 
  30.                             LEnhancedIconPane(void);                        // default constructor
  31.                             LEnhancedIconPane(const LEnhancedIconPane &inOriginal);    // copy costructor
  32.                             LEnhancedIconPane(const SPaneInfo &inPaneInfo,
  33.                                             ResIDT inIconID, Int16 inAlignment, 
  34.                                             Int16 inState, Int16 inLabel);        // build on the fly
  35.                             LEnhancedIconPane(LStream *inStream);            // build from resource
  36.         virtual                ~LEnhancedIconPane(void);
  37.         
  38.                             // Set both the icon's type and ID in one swoop.
  39.                             // set/get the alignment of the drawn icon in the pane
  40.         virtual Int16        GetAlignment(void) const;
  41.         virtual void         SetAlignment(Int16 inAlignment);
  42.         
  43.                             // set/get the state of the drawn icon in the pane
  44.         virtual Int16        GetIconState(void) const;
  45.         virtual void         SetIconState(Int16 inIconState);
  46.         
  47.                             // set/get the label of the drawn icon in the pane
  48.         virtual Int16        GetIconLabel(void) const;
  49.         virtual void        SetIconLabel(Int16 inIconLabel);
  50.  
  51.     protected:
  52.         Int16                mAlignment;
  53.         Int16                mState;
  54.         Int16                mLabel;
  55.         
  56.         virtual void        DrawSelf();
  57. };
  58.